<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
		<script>
			let k=20;
			//清空之前的文档流
			function showJitang(){
				let k=5; 
				for (var i = 0; i <k; i++) {
						document.write("<h1>好好学习，day day up</h1>");
				}
			}
			function show2(){ 
				for (var i = 0; i <k; i++) {
						document.write("<h1>好好学习，day day up</h1>");
				}
			}
		</script>
	</head>
	<body>
		<div >
			<button type="button" onclick="showJitang()">点击</button>
			<button type="button" onclick="show2()">点击</button>
		</div>
	</body>
</html>